package com.hoapital.outpbillwork.module.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.hoapital.outpbillwork.module.entity.ClinicMaster;
import com.hoapital.outpbillwork.module.entity.Insurance2201;
import com.hoapital.outpbillwork.module.mapper.ClinicMasterMapper;
import com.hoapital.outpbillwork.module.mapper.Insurance2201Mapper;
import com.hoapital.outpbillwork.module.service.ClinicMasterService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

/**
 * <p>
 * 服务实现类
 * </p>
 *
 * @author lvyao
 * @since 2020-11-03
 */
@Service
public class ClinicMasterServiceImpl extends ServiceImpl<ClinicMasterMapper, ClinicMaster> implements ClinicMasterService {
    @Resource
    private ClinicMasterMapper clinicMasterMapper;

    @Resource
    private Insurance2201Mapper insurance2201Mapper;

    @Override
    public String getDeptName(String deptCode) {
        return clinicMasterMapper.getDeptName(deptCode);
    }

    @Override
    public String getItemClassName(String itemClass) {
        return clinicMasterMapper.getItemClassName(itemClass);
    }

    @Override
    public boolean insertAll(ClinicMaster clinicMaster, Insurance2201 insurance2201) {
        Integer insert = clinicMasterMapper.insert(clinicMaster);
        Integer insert1 = insurance2201Mapper.insert(insurance2201);
        return true;
    }
}
